﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace TelerikAcademyOopProject
{
    public class Seller : Trader
    {
        /*==========================================*/
        //           Seller  FIELDS
        /*==========================================*/
        private List<Item> itemsToSell = new List<Item>();
        

        /*==========================================*/
        //           Seller  METHODS
        /*==========================================*/

        // Sell item and Remove it form the this
        public void SellItems(Item itemName)
        {
            // Try to sell item
            if (this.Itemes.Count != 0)
            {
                //TODO Set Engine for price calculation
            }
            else
            {
                throw new StockException("You dont have this Item to sell it");
            }
        }

        // Remove Item
        public void RemoveSellerItem(Item itemName)
        {
            this.Itemes.Remove(itemName);
        }

        // Count new Deposit Price
        public void CountPrice()
        {
            //TODO: Set precicion Price Set
        }

        
        // setItem to sell
        public void setItemToSell(StockManager manager,string ItemType, string itemId, string ItemName, Spred itemPrice, int itemCount)
        {
            manager.AddItem(ItemType, itemId, ItemName, itemPrice, itemCount);
        }

        


        // get seller Info
        public void getSellerStatus()
        {
            StringBuilder sb = new StringBuilder();
            sb.AppendLine("Seller Status:");
            sb.AppendLine("Current Seller Account -> " + this.TraderAccount.Balance);//TODO Add Currensy Set
            sb.AppendLine("Current Seller Procuts ->"); //TODO get Product list Info

            Console.WriteLine(sb.ToString());
        }
    }
}
